<template>
    <div>
        <p style="font-weight: bold" class="interfaceHead"><i class="el-icon-s-promotion"></i>信息上传</p>
        <el-divider></el-divider>
        <el-button size="mini" type="primary" @click="initReview">复审</el-button>
        <el-button size="mini" type="primary" @click="initFinal">终审</el-button>
        <el-button size="mini" type="primary" @click="initDaliy">日常审查</el-button>
        <el-table
                border
                :data="applyTable"
                style="width: 100%;margin-top: 20px">
            <el-table-column
                    prop="id"
                    label="序号"
                    align="center"
                    width="100">
            </el-table-column>
            <el-table-column
                    prop="name"
                    label="单位名称"
                    align="center"
                    width="160">
            </el-table-column>
            <el-table-column
                    prop="address"
                    label="地址"
                    align="center"
                    width="130">
            </el-table-column>
            <el-table-column
                    label="操作"
                    align="center">
                <template slot-scope="scope">
                    <el-button
                            size="mini"
                            @click="handleEdit(scope.$index, scope.row)">上传
                    </el-button>
                </template>
            </el-table-column>
        </el-table>
    </div>
</template>

<script>
    export default {
        name: "HealthSupApply",
        data() {
            return {
                applyTable: [],
            }
        },
        mounted() {
            this.inittable();
        },
        methods:{
            handleEdit(){
                this.$router.replace('/healthSup/healthSupapplysubmit');
            },
            inittable(){
                this.getRequest('/check/showc').then(resp=>{
                    if(resp){
                        console.log(resp);
                        this.applyTable = resp.data.data;
                    }
                })
            },
            initReview(){
                this.getRequest('/check/showF').then(resp=>{
                    if(resp){
                        this.applyTable = resp.data.data;
                    }
                })
            },
            initFinal(){
                this.getRequest('/check/showZ').then(resp=>{
                    if(resp){
                        this.applyTable = resp.data.data;
                    }
                })
            },
            initDaliy(){
                this.getRequest('/check/showR').then(resp=>{
                    if(resp){
                        this.applyTable = resp.data.data;
                    }
                })
            }
        }
    }
</script>

<style scoped>

</style>
